/*
 * Cook.java
 * Copyright (c) 2014, 2019, Kiri. 
 * All rights reserved.
 */
package com.onesalt.domain;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Lob;
import javax.persistence.Transient;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

/**
 * 用户
 *
 * @author kiri
 * @date 2015年3月5日
 * @version 1.0
 */
@Entity(name = "t_user")
@JsonIgnoreProperties({ "hibernateLazyInitializer", "handler" })
public class User implements Serializable {

	public static class CookAuditStatus {
		public static final String PASS = "PASS";
		public static final String IN_PROGRESS = "IN_PROGRESS";
	}
	
	private static final long serialVersionUID = -7979798351246582429L;

	@Id
	@GeneratedValue
	private Long userId;

	// 用户名
	private String username;

	// 密码
	private String password;

	// 用户序号（显示用）
	private String sn;

	// 名字
	private String name;

	// 联系电话
	private String tel;

	// 手机号
	@Column(unique = true)
	private String mobile;

	// 性别
	private String sex;

	// 年龄
	private Integer age;

	// 头像
	private String photo;

	// 所在城市
	private String city;

	// 微信
	@Column(unique = true)
	private String wechat;

	// 新浪微博
	@Column(unique = true)
	private String sinaWeibo;

	// 创建时间
	private Date createTime = new Date();

	// 邮箱
	private String email;

	// 备注
	private String notes;

	// 职业
	private String profession;

	// 个人经历
	@Lob
	private String vitae;

	private Double lat;

	private Double lon;

	private String address;

	private String province;

	private String district;
	
	// 擅长厨艺
	private String cookSkills;

	// 就餐人数
	private Integer diningCount;

	// 厨子申请时间
	private Date cookApplyTime;

	// 审核状态
	private String cookAuditStatus;

	// 第几位通过审核
	private Long cookPassIndex;

	// 审核时间
	private Date cookAuditTime;

	@Transient
	private UserLogin login;

	@Transient
	private Kitchen kitchen;

	public Long getUserId() {
		return userId;
	}

	public void setUserId(Long userId) {
		this.userId = userId;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getSn() {
		return sn;
	}

	public void setSn(String sn) {
		this.sn = sn;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getTel() {
		return tel;
	}

	public void setTel(String tel) {
		this.tel = tel;
	}

	public String getMobile() {
		return mobile;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	public String getSex() {
		return sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public Integer getAge() {
		return age;
	}

	public void setAge(Integer age) {
		this.age = age;
	}

	public String getPhoto() {
		return photo;
	}

	public void setPhoto(String photo) {
		this.photo = photo;
	}

	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}

	public String getWechat() {
		return wechat;
	}

	public void setWechat(String wechat) {
		this.wechat = wechat;
	}

	public String getSinaWeibo() {
		return sinaWeibo;
	}

	public void setSinaWeibo(String sinaWeibo) {
		this.sinaWeibo = sinaWeibo;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getNotes() {
		return notes;
	}

	public void setNotes(String notes) {
		this.notes = notes;
	}

	public String getProfession() {
		return profession;
	}

	public void setProfession(String profession) {
		this.profession = profession;
	}

	public String getVitae() {
		return vitae;
	}

	public void setVitae(String vitae) {
		this.vitae = vitae;
	}

	public UserLogin getLogin() {
		return login;
	}

	public void setLogin(UserLogin login) {
		this.login = login;
	}

	public Double getLat() {
		return lat;
	}

	public void setLat(Double lat) {
		this.lat = lat;
	}

	public Double getLon() {
		return lon;
	}

	public void setLon(Double lon) {
		this.lon = lon;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getProvince() {
		return province;
	}

	public void setProvince(String province) {
		this.province = province;
	}

	public String getDistrict() {
		return district;
	}

	public void setDistrict(String district) {
		this.district = district;
	}

	public String getCookSkills() {
		return cookSkills;
	}

	public void setCookSkills(String cookSkills) {
		this.cookSkills = cookSkills;
	}

	public Integer getDiningCount() {
		return diningCount;
	}

	public void setDiningCount(Integer diningCount) {
		this.diningCount = diningCount;
	}

	public Date getCookApplyTime() {
		return cookApplyTime;
	}

	public void setCookApplyTime(Date cookApplyTime) {
		this.cookApplyTime = cookApplyTime;
	}

	public String getCookAuditStatus() {
		return cookAuditStatus;
	}

	public void setCookAuditStatus(String cookAuditStatus) {
		this.cookAuditStatus = cookAuditStatus;
	}

	public Long getCookPassIndex() {
		return cookPassIndex;
	}

	public void setCookPassIndex(Long cookPassIndex) {
		this.cookPassIndex = cookPassIndex;
	}

	public Date getCookAuditTime() {
		return cookAuditTime;
	}

	public void setCookAuditTime(Date cookAuditTime) {
		this.cookAuditTime = cookAuditTime;
	}

	public Kitchen getKitchen() {
		return kitchen;
	}

	public void setKitchen(Kitchen kitchen) {
		this.kitchen = kitchen;
	}

}
